home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 5267 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.2 KB

  1. Path: news1.cle.ab.com!usenet
  2. From: don.phillips@ab.com (Donald-Anthony C. Phillips)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: gets(rec->num);  I don't know what I am doing wrong...
  5. Date: Fri, 09 Feb 1996 16:14:33 GMT
  6. Organization: The Allen-Bradley Co., Inc
  7. Distribution: inet
  8. Message-ID: <4ffhbo$qm4@news1.cle.ab.com>
  9. References: <4fempt$mjg@aphex.direct.ca>
  10. NNTP-Posting-Host: abpc386.cle.ab.com
  11. X-Newsreader: Forte Free Agent 1.0.82
  12.  
  13. Part of your problem may be that gets() is defined as gets(char *s).
  14. You are passing all sorts of values to gets(), i.e., gets(rec->id)
  15. where id is of type int.  Note that enumerated types are integer
  16. constant values.  So again you are using gets(rec->major) which is not
  17. defined as char *s
  18.  
  19. Secondly, is FILE* fp the same as FILE *fp.  It appears numerous
  20. pointers are defined as TYPE* var ( unless its just my monitor) with
  21. the asterick attached to the type( maybe someone else in the group can
  22. tell if this declaration is equivalent),
  23.  
  24. I'm not real sure about your code, you may need to post the assign2.h
  25. header which you include for greater clarity.
  26.  
  27. Donald-Anthony C. Phillips
  28. Programmer/Analyst
  29.  Rockwell  Automation
  30.        ---------------------------------------
  31.         Allen-Bradley
  32. don.phillips@ab.com
  33.  
  34.